<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        var demo = "你好啊";
        console.log(demo - 12);   // NaN
        // 1.typeof  获取（判断）变量的数据类型
        // 语法结构  typeof 变量名
        console.log(typeof demo);             // string
        var number = 1233;
        console.log(typeof number);       // number
        var bl = true;
        console.log(typeof bl);         //  boolean
        var time = undefined; 
        console.log(typeof un);       // undefined
        var time = null 
        console.log(typeof time);     // object(后面再将)


        // 2.prompt 得到的数据是 string
        var age = prompt("请输入您的年龄");
        console.log(typeof age);        // string
      
      
      
  
      
  
        
    </script>
</body>
</html>